#include <stdio.h>
#include <string.h>

#include "signal_link_list.h"

Link_list_t *list = NULL;
int main(int argc, char const *argv[])
{
    if (Init_List(&list) == OK)
    {
        printf("ok\n");
    }

    if (list == NULL)
    {
        printf("error\n");
    }
    
    ElemType elem;
    strcpy(elem.name,"data structure");
    strcpy(elem.token,"1929394959");
    elem.price = 10;

    ElemType elem1;
    strcpy(elem1.name,"data structure");
    strcpy(elem1.token,"1921114959");
    elem1.price = 10;


    ElemType elem2;
    strcpy(elem2.name,"data structure");
    strcpy(elem2.token,"1922224959");
    elem2.price = 8;


    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Push_Back(list,&elem);
    Pop_Back(list);
    // Pop_Back(list);
    //Pop_Back(list);
    Push_Front(list,&elem2);
    Pop_Front(list);
    //Insert_Elem(list,4,&elem2);

    printf("%d",get_Node_Num(list));
    Insert_Node(list,6,&elem2);
    Delete_Node_Anywhere(list,6);
    Print_List(list);
    return 0;
}
